Using Resources in Printing Extensions
You must create a number of resources that define your printing extension and provide QuickDraw GX with the information that it needs to properly load and execute the extension. The resources an extension contains are defined in a printing extension file of type'pext'
. Each printing extension file must include certain resources and may include some optional resources, as shown in Table 2-5Most of these resource types are described in the chapter "Printing Resources" in this book. The panel (
'ppnl'
), extended panel ('xdtl'
), and paper type ('ptyp'
) resources are described in Inside Macintosh: QuickDraw GX Printing. This section provides examples of these resources as used in the background picture printing extension. The contents of the filebackwash.r
, which contains the resource definitions for the background picture printing extension, are shown in the QuickDraw GX sample code.To avoid conflicts with resources defined by printer drivers, application programs, and Macintosh system software, the resources that you define for your printing extension must have IDs in the range 0x9600 (-27136) through 0x97FF (-26625). Most of the resources have specific ID values that you must use with them; these IDs are shown in the examples in this chapter and are defined in the resource descriptions in the chapter "Printing Resources" in this book.
All of the resources that you define for your printing extensions need to be loaded into the system heap and need to be purgeable. System resources are stored in the system heap as opposed to the application heap, where application resources are stored. Purgeable resources can be purged by the Memory Manager when space is required, as described in Inside Macintosh: Memory. You need to specify these attributes in the first
line of every resource that you define for your extensions, as is done in every resource example in this chapter.
Subtopics
- Defining Code Segments in Your Printing Extension
- Defining Version Compatibility for Your Printing Extension
- Defining the Scope of Your Printing Extension
- Optimizing the Use of Your Extension
- Specifying Which Messages Your Extension Overrides
- Defining the Loading Order of Your Extension
Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help